<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>CSS常用值</title>
    <style>
        h1{
            color: red;
            color: rgb(255,0,0);
            color: rgb(0,255,255);
            color: rgb(0,255,0);
            color: rgb(255,0,255);
            color: rgb(0,0,255);
            color: rgb(255,255,0);
            color: #FFFFFF;
            color: #FFF;
            color: #000000;
            color: #000;
            color: #808080;/*不能简写*/

        /*   带不透明颜色度 1完全不透明 0完全透明 0.x半透明 */
            color: rgba(255,0,0,0.1);
            color: rgba(255,0,0,0.8);
            color: rgba(255,0,0,0.6);
            color: rgba(255,0,0,.4);
            color: rgba(255,0,0,.2);
            color: rgba(255,0,0,0);
        }
        .d1{
            width: 50px;
            height: 100px;
            background-image: url(img/mr.png);
            background-size: 50px 100px;
            background-color: cyan;
        }
        .d2{
            width: 500px;
            height: 300px;
            border: 5px solid red;
            background-image: url(img/mr.png);
            /*设置背景图不允许重复*/
            background-repeat: no-repeat;
            background-position: -50px 0 ;/*向左*/
            background-position: 0 50px ;/*向下*/
            background-position: -50px -50px ;/*向下*/
            background-position: center;
            background-position: 50% 50%;
            background-position: 100% 100%;/*右下角*/
        }
        .d3{
            width: 500px;
            height: 300px;
            /*线性渐变 角度值 颜色1 颜色2 ...*/
            background-image: linear-gradient(270deg, red,green,orange);
        }
    </style>
</head>
<body>
<h1>测试颜色</h1>
<!-- .d*3-->
<div class="d1"></div>
<div class="d2"></div>
<div class="d3"></div>
</body>
</html>